package com.davidk.survey.client.home;

import com.davidk.survey.client.eventbus.MasterEventBus;
import com.mvp4g.client.annotation.Presenter;
import com.mvp4g.client.presenter.BasePresenter;

@Presenter(view = HomeView.class)
public class HomePresenter extends BasePresenter<HomeViewInterface, MasterEventBus> {
	public void onStart() {
	}

	public void onLoginSuccess(String userId) {
		eventBus.changeBody(view.getView());
	}

	public void onShowFunction(String fnType, String fnData) {
		if (fnType.equals("fn") && fnData.equals("home"))
			eventBus.changeBody(view.getView());
	}
}
